package com.xudu.controller;

import com.xudu.common.LogAnnotation;
import com.xudu.common.LogType;
import com.xudu.common.Result;
import com.xudu.entity.User;
import org.springframework.web.bind.annotation.PostMapping;

/**
 * ClassName: IUserController
 * Description:
 *
 * @Author xudu
 * @Create 2024/4/18
 */
public interface IUserController {

    /**
     * 用户登陆方法接口
     * @param user
     * @return
     */
    @LogAnnotation(operation = "用户",type = LogType.LOGIN)
    @PostMapping("login")
    Result login(User user) throws Exception;

    /**
     * 用户注册方法接口
     * @param user
     * @return
     */
    @LogAnnotation(operation = "用户",type = LogType.REGISTER)
    @PostMapping("register")
    Result register(User user) throws Exception;
}